import {request} from "@/api/request";
//获取列表
export function getRoomList(page,pageSize,data){
  return request({
    url:`/api/room/list/${page}/${pageSize}`,
    method:'POST',
    data:JSON.stringify(data)
  })
}
// 添加房间
export function addRoom(data){
  return request({
    url:'/api/room/adjuration',
    method:'POST',
    data:JSON.stringify(data)
  })
}
//批量添加房间
export function addRooms(data){
  return request({
    url:'/api/room/batch_add',
    method:'POST',
    data:JSON.stringify(data)
  })
}
//删除房间
export function delRoom(roomID){
  return request({
    url:'/api/room/delete',
    method:'DELETE',
    data:roomID
  })
}
//编辑
export function editRoom(roomId,data){
  return request({
    url:`/api/room/update/${roomId}`,
    method:'PUT',
    data:JSON.stringify(data)
  })
}
